
<%= react_component("ReduxSharedStoreApp", props: { prerender: true }, prerender: true, trace: true, id: "ReduxSharedStoreApp-react-component-0") %>
<hr/>
<h1>Second Hello World</h1>
<%= react_component("ReduxSharedStoreApp", props: { prerender: true}, prerender: true, trace: true, id: "ReduxSharedStoreApp-react-component-1") %>
<hr/>

<h1>React Rails Client Side Only Rendering, 2 components, same Redux store from controller</h1>
<p>
  This example demonstrates using 2 components attached to the same store.<br/><br/>
</p>

<hr/>
<h2>Setup</h2>
<ol>
  <li>
    Create component source: spec/dummy/client/app/startup/ReduxSharedStoreApp.jsx
  </li>
  <li>
    Create store source: spec/dummy/client/app/stores/SharedReduxStore.jsx
  </li>
  <li>
    Register the component in the client-bundle & server-bundle entrypoint files: spec/dummy/client/app/packs/
  </li>
  <li>
    Register the the store in the controller spec/dummy/app/controllers/pages_controller.rb
  </li>
  <li>
    <br/>
    <pre>
redux_store("SharedReduxStore", props: @app_props_server_render)
    </pre>
    <br/>
  <li>
    Place the components: spec/dummy/app/views/pages/server_side_hello_world_shared_store_controller.html.erb
    <br/>
    <pre>
<%%= react_component("ReduxSharedStoreApp", prerender: true, trace: true, id: "ReduxSharedStoreApp-react-component-0") %>

Second Hello World
<%%= react_component("ReduxSharedStoreApp", prerender: true, trace: true, id: "ReduxSharedStoreApp-react-component-1") %>
    </pre>
  </li>
</ol>
